package com.ee.chat.common.serconfig;

import com.ndhutu.ee.util.ali.sts.STSConfig;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

@Component
public class MyAliSTSConfig implements STSConfig {
    @Value("${ali.accessKey.accessKeyId}")
    private String accessKeyId;
    @Value("${ali.accessKey.accessKeySecret}")
    private String accessKeySecret;
    @Value("${ali.sts.endpoint}")
    String endpoint;
    @Value("${ali.sts.roleArn}")
    String roleArn;
    @Value("${ali.sts.roleSessionName}")
    String roleSessionName;
    @Value("${ali.sts.policy}")
    String policy;

    @Override
    public String getAccessKeyId() {
        return accessKeyId;
    }

    @Override
    public String getAccessKeySecret() {
        return accessKeySecret;
    }

    @Override
    public String getEndpoint() {
        return endpoint;
    }

    @Override
    public String getRoleArn() {
        return roleArn;
    }

    @Override
    public String getRoleSessionName() {
        return roleSessionName;
    }

    @Override
    public String getPolicy() {
        return policy;
    }
}
